// export const baseUrl = "http://106.14.41.55:7071/";
// export const baseUrl = "https://api.hzyisu.com/";

let APP_BASE_URL, MALL_BASE_URL, PAY_BASE_URL, DING_PAY_URL;
if (process.env.NODE_ENV === 'production') {
    APP_BASE_URL = "https://api.hzyisu.com/";
    MALL_BASE_URL = "http://bapi.hzyisu.com/";
    PAY_BASE_URL = "http://192.168.8.166:8080/";
    DING_PAY_URL = "https://api.ddbaoxiang.com/recharge/createRechargeOrder";
} else {
    APP_BASE_URL = "https://api.hzyisu.com/";
    MALL_BASE_URL = "http://bapi.hzyisu.com/";
    PAY_BASE_URL = "http://192.168.8.166:8080/";
    DING_PAY_URL = "http://192.168.8.172:3500/recharge/createRechargeOrder";
}


export const API = {
    getjsapiticket: APP_BASE_URL + 'wechat/getjsapiticket',//获取微信授权
    querySaleGoodsBannerInfo: APP_BASE_URL + 'salesgoods/querySaleGoodsBannerInfo',//banner 信息
    querySaleGoodsList: APP_BASE_URL + 'salesgoods/querySaleGoodsList',//列表
    buyNumConfig: APP_BASE_URL + 'config/buyNumConfig',//配置】获取一元秒商品购买上限相关配置
    getGoodsInfo: APP_BASE_URL + 'goods/getGoodsInfo',//详情页
    getWinningRecordHistoryList: APP_BASE_URL + 'winningrecord/getWinningRecordHistoryList',//往期揭晓列表
    getRecentlyAnnounced: APP_BASE_URL + 'winningrecord/getRecentlyAnnounced',//最近揭晓列表
    getWinningAlgorithm: APP_BASE_URL + 'order/getWinningAlgorithm',//计算详情
    CreateOrder: APP_BASE_URL + 'order/CreateOrder',//创建订单
    orderShow: APP_BASE_URL + 'order/orderShow',//创建订单
    getPaymentData: APP_BASE_URL + 'order/getPaymentData', //获取支付信息
    getListByOrderId: APP_BASE_URL + 'luckyNumber/getListByOrderId',// 获取订单幸运号


    queryAddressInfo: APP_BASE_URL + 'userAddress/list',//获取用户地址信息
    delAddress: APP_BASE_URL + 'userAddress/delete',//获取删除用户地址信息
    addAddress: APP_BASE_URL + 'userAddress/insert',//获取添加用户地址信息
    modifyAddress: APP_BASE_URL + 'userAddress/update',//获取添加用户地址信息

    myOrderList: APP_BASE_URL + 'order/myorderlist',//获取我的抢宝记录
    myOrderDetail: APP_BASE_URL + 'order/orderDetail',//获取抢宝记录详情
    myShowInfo: APP_BASE_URL + 'order/getMyOrderShowInfo',//获取我的晒单记录
    myShowDetail: APP_BASE_URL + 'order/getOrderShowInfo',//获取晒单记录详情
    logisticsInfo: APP_BASE_URL + 'order/LogisticsInfo',//获取晒单记录详情
    winShowInfo: APP_BASE_URL + 'order/getOrderShowList',//获取赢家晒单记录

    //商城
    mainPageData: MALL_BASE_URL + 'module/moduleData',//首页数据
    mainPageDataByPage: MALL_BASE_URL + 'module/getRecommendGoodsByPage',//首页翻页
    goodsDetail: MALL_BASE_URL + 'goodsInfo/getGoodsDetail',//商品详情
    goodsConfig: MALL_BASE_URL + 'goodsInfo/getGoodsInfoForBuy',//商品规格
    saveOrder: MALL_BASE_URL + 'order/createOrder',//下单接口
    paymentData: MALL_BASE_URL + 'order/getPaymentData',//请求支付数据
    categoryGoods: MALL_BASE_URL + 'goodsInfo/getGoodsListByCategoryCode',//二级分类商品
    searchGoods: MALL_BASE_URL + 'goodsInfo/getGoodsListByQuery',//搜索商品
    myOrderStatus: MALL_BASE_URL + 'order/getOrderStatusNum',//用户订单状态
    getOrderList: MALL_BASE_URL + 'order/getOrderList',//用户订单列表
    cancelOrder: MALL_BASE_URL + 'order/cancelOrder',//取消订单
    orderDetail: MALL_BASE_URL + 'order/getOrderDetail', //订单详情
    confirmDeliveryGoods: MALL_BASE_URL + 'order/confirmDeliveryGoods',//确认收货

    sendValidateCode: APP_BASE_URL + "user/sendValidateCode",//发送验证码
    userLogin: APP_BASE_URL + "user/login",//用户登录

    //支付
    queryMerchantInfo: PAY_BASE_URL + "shopInfo/getShopInfoByShopNo",//根据商户ID查询商户信息
    sendValidateCodeToPhone: PAY_BASE_URL + "mine/sendValidateCode",//发送验证码到手机
    verificationCode: PAY_BASE_URL + "staff/affirmRelationship",//判断验证码是否正确
    mineInfo: PAY_BASE_URL + "mine/mineInfo",//我的页面权限判断
    updateNoticeSwitchStatus: PAY_BASE_URL + "mine/updateNoticeSwitchStatus",//更新通知开关状态
    addEmployee: PAY_BASE_URL + "staff/createRelationship",//添加员工
    getShopListByOpenId: PAY_BASE_URL + "shopInfo/getShopListByOpenId",//通过openId获取商户列表
    getStaffList: PAY_BASE_URL + "staff/getStaffList",//通过openId获取店铺员工列表
    updateStaff: PAY_BASE_URL + "staff/updateStaff",//修改员工信息
    deleteStaff: PAY_BASE_URL + "staff/delStaff",//删除员工信息
    queryOrderList: PAY_BASE_URL + "order/queryOrderList",//查询商户订单
    exportBill: PAY_BASE_URL + "order/exportBill",//导出订单以邮箱发送
    getShopOrderList: PAY_BASE_URL + "order/getShopOrderList",//获取店铺订单列表
    getShopPayQrCode: PAY_BASE_URL + "shopInfo/getShopPayQrCode",//获取收款二维码
    createRelationshipAgain: PAY_BASE_URL + "staff/createRelationshipAgain",//重复获取二维码

    onlinePay: "http://192.168.206.225:8080/payment/fuYouCreateOrder",//线上支付测试接口
    //onlinePay: "http://192.168.1.102:8083/payment/fuYouCreateOrder",


    //叮叮
    dingPayCharge: DING_PAY_URL //get charge
};
